%%%-------------------------------------------------------------------
%%% @author Rain
%%% @copyright (C) 2022, <COMPANY>
%%% @doc
%%%
%%% @end
%%% Created : 16. 5月 2022 10:15
%%%-------------------------------------------------------------------
-author("Rain").

-define(DEFAULT_TOWER_X, 100).  %% 默认灯塔X间距
-define(DEFAULT_TOWER_Y, 100).  %% 默认灯塔Y间距
-define(AOI_VIEWPORT_SIZE, 2).  %% 视野半径大小

-define(OBJ_AOI_TYPE_OBJECT, 1). %% Object的Aoi类型 - Object
-define(OBJ_AOI_TYPE_WATCHER, 2). %% Object的Aoi类型 - Watcher

-define(ETS_UID, ets_uid).

-record(tower_data, {
    aoi_pos,
    object_maps = #{}, %% #{UidValue => #object{}}
    watchers = [] %% 观察者列表 [#object{}|...]
}).


-record(object, {
    uid_value = 0,
    uid, %% #uid{}
    x = 0,
    y = 0
}).
